/* Source file https://github.com/MrOtherGuy/firefox-csshacks/tree/master/chrome/dark_additional_windows.css made available under Mozilla Public License v. 2.0
See the above repository for updates as well as full license text. */

/* Dark library, page-info and bookmark-properties */
/* Color scheme matches default dark theme */

/* If you are going to open Library in the (places.xhtml) in a tab then this file should also be imported in userContent.css */

@namespace xul url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul");

@-moz-document url(chrome://browser/content/places/places.xhtml),
  url(chrome://browser/content/places/bookmarkProperties.xhtml),
  url(chrome://global/content/commonDialog.xhtml),
  url-prefix(chrome://browser/content/preferences/dialogs/),
  url("chrome://mozapps/content/handling/dialog.xhtml"),
  url-prefix(chrome://browser/content/pageinfo/),
  url-prefix(chrome://browser/content/sanitize.xhtml),
  url-prefix("chrome://mozapps/content/downloads"){
  :root{
    background-color: #2b2a33 !important;
    --in-content-box-background: #23222b !important;
  }
  #placesToolbox,
  #placesView,
  #placesToolbar,
  #main-window,
  #topBar,
  dialog,
  tree{
    -moz-appearance: none !important;
    color: rgb(249,249,250) !important;
  }
    
  #placesToolbar,
  tree{
    background: transparent !important;
  }
  
  #imagecontainerbox{ background: url("chrome://global/skin/media/imagedoc-darknoise.png") !important }
  
  search-textbox,
  #searchFilter,
  menulist,
  input,  
  textbox,
  richlistbox,
  treecol,
  treecolpicker,
  button,
  menu,
  #permList{
    -moz-appearance: none !important;
    color: inherit !important;
  }
  
  menulist{ border: 1px solid graytext; padding-inline-end: 4px }
  dropmarker{ filter: invert(1) }
  menulist:hover{ border-color: highlight; background-color: rgba(255,255,255,0.1) }
    
  .menubar-left{ fill: currentColor; -moz-context-properties: fill; }
  #topBar,#searchFilter,search-textbox,input,textbox,richlistbox{ background-color: rgba(0,0,0,0.2) !important; }
  input[mozactionhint="search"],input[readonly],td > input{ background-color: transparent !important; }
    
  treecol:not([hideheader]){ height: 24px; }
  treecol:hover{ filter: brightness(160%) }
  treechildren::-moz-tree-row(multicol, odd), #permList{ background-color: rgba(0,0,0,0.2) !important; }
  
  radiogroup > radio[selected],
  radiogroup > radio:hover,
  #permList > .permission:hover,
  treechildren::-moz-tree-row(hover),
  button:hover{ background-color: rgba(255,255,255,0.1) !important; color: inherit !important;}
  
  treechildren::-moz-tree-row(selected){ background-color: Highlight !important; }
  button{ padding: 3px }
  #placesMenu > menu{ border: none !important; }
    
  search-textbox,input,button{ border: 1px solid graytext; border-radius: 3px }
  search-textbox,input{ padding: 2px }

}

/* modal prompts (alert() & friends) */

xul|vbox.paymentDialogContainerFrame,
xul|vbox.tabmodalprompt-mainContainer{
  background-color: var(--toolbar-bgcolor) !important;
  color: var(--lwt-text-color,-moz-dialogtext) !important;
}